package com.kfm.base.net;

import java.net.InetAddress;
import java.net.UnknownHostException;

public class Demo {

    public static void main(String[] args) {
        try {
//            InetAddress localHost = InetAddress.getLocalHost();
            InetAddress localHost = InetAddress.getByName("BAOBAO");
            System.out.println(localHost);
        } catch (UnknownHostException e) {
            throw new RuntimeException(e);
        }

    }
}
